﻿<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Login and Registration</title>
  <link rel="stylesheet" href="login-register.css">
</head>

<body>
  <div class="container">
    <div class="tab-content" id="login">
      <h2>登录</h2>
      <form id="loginForm">
        <label for="loginUsername">用户名:</label>
        <input type="text" id="loginUsername" placeholder="Username" required><br>
        <label for="loginPassword">密码:</label>
        <input type="password" id="loginPassword" placeholder="Password" required><br>
        <button type="submit">登录</button>
      </form>
      <p>没有账号? <a href="#" onclick="showTab('register')">去注册</a></p>
    </div>
    <div class="tab-content" id="register" style="display: none;">
      <h2>注册</h2>
      <form id="registerForm">
        <label for="registerUsername">用户名:</label>
        <input type="text" id="registerUsername" placeholder="Username" required><br>
        <label for="registerPassword">密码:</label>
        <input type="password" id="registerPassword" placeholder="Password" required><br>
        <label for="registerConfirmPassword">确认密码:</label>
        <input type="password" id="registerConfirmPassword" placeholder="Confirm Password" required><br>
        <button type="submit">注册</button>
      </form>
      <p>已有账号? <a href="#" onclick="showTab('login')">去登录</a></p>
    </div>
  </div>

  <script src="login-register.js"></script>
</body>

</html>